import { defineStore } from 'pinia';

export const useZhichengStore = defineStore('zhicheng', {
  state: () => {
    return {
      showAlertInfo: {
        isShow: false,
        message: '',
        delay: 3000,
        title: '提示',
      },
    };
  },
  getters: {},
  actions: {
    //showalert弹窗
    changeShowAlert(info) {
      console.log(this.showAlertInfo, info);
      this.showAlertInfo.isShow = info.isShow;
      this.showAlertInfo.message = info.message;
      this.showAlertInfo.isShow = info.delay;
      this.showAlertInfo.title = info.title;

      //   state.showAlertInfo.isShow = info.isShow;
    },
  },
});
